package com.ynny.abstract_.demo01;

public class GeometryTest {

    public static void main(String[] args) {
        //抽象类不能实例化
//        new Geometry();

        //抽象：其实是 面向对象 继承 多态 的 思想提升
        //javac  .java  .class
        //java   类名
        //编译看左边，运行看右边的
        Geometry geometry = new Circle();
        geometry.r = "半径";
        System.out.println(geometry);
        geometry.area();

        Geometry rectangle = new Rectangle();
//        rectangle.width = 10;

        rectangle.area();

    }
}
